package user;

import book.Bookshelf;
import operation.IOperation;

public abstract class User {
    protected String name;
    //除非其他包继承该类并使用super调用，否则无法调用
    protected IOperation[] iOperations;

    public User(String name) {
        this.name = name;
        //构造方法
    }
    public abstract int menu();

    public void doOperation(int choice, Bookshelf bookshelf) {
        iOperations[choice].work(bookshelf);
    }
}
